def fib(max):
    n, a, b = 0, 0, 1
    while n < max:
        print(b)
        a, b = b, a + b
        n = n + 1
    return 'done'


fib(10)


def odd():
    print('step 1')
    yield 1
    print('step 2')
    yield (3)
    print('step 3')
    yield (5)


o = odd()
next(o)
print("=====")
next(o)
print("=====")
next(o)
print("=====")
print([1] + [1])
print("=====")


def hello_yield():
    L = [1]
    while True:
        yield L
        L = [1] + [L[n] + L[n - 1] for n in range(1, len(L))] + [1]


hello = hello_yield()
print(next(hello))
print(next(hello))
print(next(hello))
print(next(hello))
print(next(hello))
print(next(hello))
print(next(hello))
print(next(hello))
print(next(hello))
